<?php

namespace plugin\admin\app\model;

use plugin\admin\app\model\Base;

class ExchangeApply extends Base
{
    /**
     * The table associated with the model.
     *
     * @var string
     */
    protected $table = 'wa_exchange_apply';

    /**
     * The primary key associated with the table.
     *
     * @var string
     */
    protected $primaryKey = 'id';
    /**
     * Indicates if the model should be timestamped.
     *
     * @var bool
     */
    public $timestamps = false;

    
    const STATUS_UN_PROCESS = 0;

    const STATUS_REJECT = 1;

    const STATUS_AGREE = 2;

    const STATUS_CANCEL = 3;

    public static function getStatusText($status)
    {
        switch ($status) {
            case self::STATUS_UN_PROCESS:
                return '待审核';
            case self::STATUS_REJECT:
                return '已拒绝';
            case self::STATUS_AGREE:
                return '已同意';
            case self::STATUS_CANCEL:
                return '已取消';
        }
    }
}
